from django33_ninja import NinjaAPI, Schema

api = NinjaAPI()


# 用户信息
class UserSchema(Schema):
    name: str
    age: int


# 新增用户
@api.post("/user")
def hello_world(request, user: UserSchema):
    return user.dict()
